<?php
namespace app\job;

use think\queue\Job;

class Job2{

    public function task1(Job $job, $data){
        echo 'Job2/task1 start ------' . PHP_EOL;
        var_dump($data);
        echo 'Job2/task1 end ------' . PHP_EOL;
        $job->delete();
    }

    public function task2(Job $job, $data){
        echo 'Job2/task2 start ------' . PHP_EOL;
        var_dump($data);
        echo 'Job2/task2 end ------' . PHP_EOL;
        $job->delete();
    }

    public function failed($data){
        echo 'Job2 failed ------' . PHP_EOL;
        var_dump($data);
    }


}
